﻿<%@ Register TagPrefix="mnu" Namespace="Mysoft.Map.Application.Menus" Assembly="Mysoft.Map.Application.Components" %>
<%@ Register TagPrefix="mwc" Namespace="MySoft.WebControls" Assembly="MySoft.WebControls" %>
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="Zkgl_ZkItem_Grid.aspx.vb" Inherits="Slxt.Zkgl_ZkItem_Grid"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
	<HEAD>
		<title>折扣明细</title>
		<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
		<meta content="Visual Basic .NET 7.1" name="CODE_LANGUAGE">
		<meta content="JavaScript" name="vs_defaultClientScript">
		<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
		<link rel="stylesheet" type="text/css" href="/_nav/menu.css" />
		<link rel="stylesheet" type="text/css" href="/_common/styles/global.css" />
		<link rel="stylesheet" type="text/css" href="/_grid/map_grid.css" />
		<link rel="stylesheet" type="text/css" href="/_forms/styles/form.css" />
		<link rel="stylesheet" type="text/css" href="/_common/styles/select.css" />
		
		<script language="javascript" src="/_common/scripts/global.js"></script>
		<script language="javascript" src="/_forms/FormBase.js"></script>
		<script language="javascript" src="/_controls/setting.js"></script>
		<script language="javascript" src="/_controls/util/util.js"></script>
		<script language="javascript" src="/_controls/datetime/date.js"></script>
		<script language="javascript" src="/_controls/number/number.js"></script>
		<script language="javascript" src="/_grid/rep_grid.js"></script>
		<script language="javascript" src="/_nav/menu.js"></script>
		<script language="javascript" src="/slxt/js/Public.js"></script>
		<script language="javascript" src="/PubProject/js/Public.js"></script>
		<script language="javascript" src="/SLXT/XSXC/XSXC_Public.js"></script>
		<script language="javascript" src="/SLXT/XTCS/Zkgl_ZkItem_Grid.js"></script>
		<script language="javascript">
		    var sDeleteOidList = "";             //删除行的oid集合,以","号分隔

		    function window.onload()
		    {
		         				//初始化 Repeater 中的表格(id=gridBar)
		        initRepeater(gridBar);
                //初始化列表为'-'的列居中
		        var o = document.all("gridBar");
		        for (var i = 1; i < o.rows.length; i++) {
		            if (o.rows[i].children[4].innerHTML=="-") {
		                o.rows[i].children[4].align = "center";
		            }
		            if (o.rows[i].children[5].innerHTML== "-") {
		                o.rows[i].children[5].align = "center";
		            }
		        }
		    }

		    //初始化
		    function initRepeater(obj) {
		        initGrid(obj)
		        var head = obj.rows[0];
		        head.id = "trHeader";
		        head.setAttribute("align", "center");

		        var cell;
		        for (var i = 0, j = head.cells.length; i < j; i++) {
		            cell = head.cells[i];
		            cell.className = "gridBar";
		            cell.style.background = "#E9E7D7 url(/_imgs/bar_line.gif) no-repeat right"
		            if (i == 0 && obj.MultiSelect == "true") {
		                cell.innerHTML = '<input type="checkbox" id="chkAll" title="选择本页所有记录" onclick="DoCheckAll(this,\'Repeater\')" />'
		            }
		            else {
		                cell.innerHTML = "<nobr>" + cell.innerHTML + "</nobr>"
		            }
		        }
		        var string = '<table width="100%" cellpadding="0" cellspacing="0" border="0" style="position:absolute; top:expression(this.offsetParent.scrollTop)">' + head.outerHTML + '</table>'
		        obj.parentNode.insertAdjacentHTML("afterBegin", string);
		    }
		</script>
		<style>
			.iNoborder { BORDER-RIGHT: medium none; BORDER-TOP: medium none; BORDER-LEFT: medium none; WIDTH: 100%; BORDER-BOTTOM: medium none; BACKGROUND-COLOR: transparent }
		</style>
	</HEAD>
	<body MS_POSITIONING="GridLayout">
		<form id="crmForm" method="post" runat="server">	
			<table style="FONT-SIZE: 9pt" height="100%" cellSpacing="0" cellPadding="0" width="100%" >
				<TBODY>
					<tr height="1">
						<td><mnu:appgridmenu id="appGridMenu" runat="server"></mnu:appgridmenu></td>
					</tr>
					<tr>
						<td>
						    <%--Repeater开始--%>
                    <div style=" position:relative; height:100%; overflow:auto">
                        <table id="gridBar" width="100%"  MultiSelect="false"  cellpadding="0" cellspacing="0" border="0"  gridID="myRep" onclick="handleClick();" ondblclick="openModiWin();" style="table-layout:fixed" >
                            <tr id="tr1">
                               <td align="center" width="40" class="gridBar">序号</td>
															
							    <td class="gridBar" width="150">折扣项名称<% Repeater1.GetSortText("DiscntName") %></td>
    							
							    <td class="gridBar" width="80">折扣范围<% Repeater1.GetSortText("DiscntScope")%></td>	
    							
							    <td class="gridBar" width="80">计算方法<% Repeater1.GetSortText("CalMethod") %></td>
    							
							    <td class="gridBar" width="80">折扣(%)<% Repeater1.GetSortText("DiscntValue") %></td>
    							
							    <td class="gridBar" width="110">优惠金额(元)<% Repeater1.GetSortText("PreferentialPrice") %></td>
    							
							    <td class="gridBar" width="110">生效日期<% Repeater1.GetSortText("BgnDate")%></td>
    							
							    <td class="gridBar">失效日期<% Repeater1.GetSortText("EndDate")%></td>
                            </tr>
                            <mwc:Repeater ID="Repeater1" runat="server" SortSignDESC='<img src="/_imgs/ico_arrow_d.gif">' SortSignASC='<img src="/_imgs/ico_arrow_u.gif">' PKField="HsCostGUID" EnablePager="false">
                                <ItemTemplate>
                                    <tr height="24" oid='<%# DataBinder.Eval(Container.DataItem, "DiscntGUID") %>' DiscntPlanGUID='<%# DataBinder.Eval(Container.DataItem, "DiscntPlanGUID") %>'  ProjGUID='<%# DataBinder.Eval(Container.DataItem, "ProjGUID") %>' Remark='<%# DataBinder.Eval(Container.DataItem, "Remark") %>' IsAllowChange='<%# DataBinder.Eval(Container.DataItem, "IsAllowChange") %>' Sequence='<%# DataBinder.Eval(Container.DataItem, "Sequence") %>'>
										<td  class="gridBorder" align="center"><%#Container.ItemIndex + 1%></td>
                                        <td  class="gridBorder" align="left" name="DiscntName" type="" ><nobr title="<%#DataBinder.Eval(Container.DataItem, "DiscntName")%>"><%#DataBinder.Eval(Container.DataItem, "DiscntName")%></nobr></td>
                                        <td  class="gridBorder" align="left" name="DiscntScope" type=""><%#DataBinder.Eval(Container.DataItem, "DiscntScope")%></td>
                                        <td  class="gridBorder" align="right" name="CalMethod" type=""><%#DataBinder.Eval(Container.DataItem, "CalMethod")%></td>
                                        <td  class="gridBorder" align="right" name="DiscntValue" type="money"><%#DataBinder.Eval(Container.DataItem, "DiscntValue")%></td>
                                        <td  class="gridBorder" align="right" name="PreferentialPrice" type="money"><%#DataBinder.Eval(Container.DataItem, "PreferentialPrice")%></td>
                                        <td  class="gridBorder" align="center" name="BgnDate" type=""><%#DataBinder.Eval(Container.DataItem, "BgnDate")%></td>
                                        <td  class="gridBorder" align="center" name="EndDate" type=""><%#DataBinder.Eval(Container.DataItem, "EndDate")%></td>
									</tr>
                                </ItemTemplate>
                            </mwc:Repeater>
                        </table>
                    </div>
                    
                    <%--Repeater结束--%>
	
			            </TD>
			        </TR>
			    </TBODY>
			</TABLE>
			</form>
	</body>
</HTML>




